# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=webscarab
pkgver=20120422.001828
pkgrel=9
groups=('blackarch' 'blackarch-fuzzer' 'blackarch-proxy' 'blackarch-scanner' 'blackarch-webapp')
pkgdesc="Framework for analysing applications that communicate using the HTTP and HTTPS protocols"
arch=('any')
url='http://www.owasp.org/index.php/Category:OWASP_WebScarab_Project'
license=('GPL2')
depends=('java-environment')
noextract=("$pkgname-one-${pkgver/./-}.jar")
source=("http://dawes.za.net/rogan/webscarab/$pkgname-one-${pkgver/./-}.jar")
sha512sums=('8a36397fe3b74250e9afb716cfb34ffae765aca049d722cd2778e3998c79700f831ce2d8251c95320abfb3cd9438146319ea86e1261f11aa68cab69e7df15e55')

package() {
  install -dm 755 "$pkgdir/usr/bin"

  install -Dm 755 webscarab-one-${pkgver/./-}.jar \
    "$pkgdir/usr/share/$pkgname/$pkgname.jar"

  cat > "$pkgdir/usr/bin/$pkgname" << EOF
#!/bin/sh
exec java -jar /usr/share/$pkgname/$pkgname.jar "\$@"
EOF

  chmod +x "$pkgdir/usr/bin/$pkgname"
}

